﻿@model LtiLibrary.Lti1.LtiRequestViewModel

@{
    Layout = "~/Views/Shared/_LayoutEmpty.cshtml";
}

@* 
The Controller calculated all the form data, and even the
form action. All this view needs to do is create the form and ask
the browser to submit it.
*@
<form id="form" action="@Model.Action" method="post">
    @foreach (var name in Model.Fields.AllKeys)
    {
        <input type="hidden" name="@name" value="@Model.Fields[name]" />
    }
    <input type="hidden" name="oauth_signature" value="@Model.Signature" />
</form>

@section Scripts {
<script>
    $(function () {
        $("#form").submit();
    });
</script>
}